﻿using System.Collections.Generic;

namespace Zocono.WCS.Admin.Models.ConfigManager
{
    public class PlcReadDbSearchPageData
    {
        public long ID { get; set; }
        public string Js_Id { get { return ID.ToString(); } }
        /// <summary>
        /// 任务关联id
        /// </summary>
        public long JobID { get; set; }
        /// <summary>
        /// plc连接关联Id
        /// </summary>
        public long PlcConnectionID { get; set; }
        public string EquipmentCode { get; set; }
        /// <summary>
        /// db编号
        /// </summary>
        public int DbCode { get; set; }
        /// <summary>
        /// db读取起始位
        /// </summary>
        public int DbStart { get; set; }
        /// <summary>
        /// db读取长度
        /// </summary>
        public int DbLength { get; set; }
        /// <summary>
        /// 是否心跳
        /// </summary>
        public bool IsHeartbeat { get; set; }
        /// <summary>
        /// 是否可用
        /// </summary>
        public bool IsEnable { get; set; }
        /// <summary>
        /// 报文处理模块类型，用于工厂创建报文处理模块对象
        /// </summary>
        public string ProcessModuleType { get; set; }
        /// <summary>
        /// 报文处理模块对象的名称
        /// </summary>
        public string ProcessModuleName { get; set; }
        /// <summary>
        /// PLC名称其实由 jobname和plcconnectID确定一个
        /// </summary>
        public string PlcName { get; set; }
        public List<PlcJobSearchPageData> JobSearchs { get; set; }
        public List<PlcIPSearchPageData> PlcIpSearchs { get; set; }
    }

    public class PlcJobSearchPageData
    {
        public string JobId { get; set; }
        public string JobName { get; set; }
    }

    public class PlcIPSearchPageData
    {
        public string PlcConnectId { get; set; }

        public string PlcConnectIp { get; set; }
        public string ScEquipmentCode { get; set; }
    }
}
